function ret=init_stack(l)
 x.stack={};
 x.length=l;
 x.tmpsize=0;
 x.mat=eye(2);
 ret=x;
endfunction
